Optimal. Leaf size=17 \[ a x-\frac{b \tanh ^{-1}(\sin (c+d x))}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0442866, antiderivative size = 17, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 30, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.067, Rules used = {4042, 3770} \[ a x-\frac{b \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4042
Rule 3770
Rubi steps
\begin{align*} \int \frac{a^2-b^2 \sec ^2(c+d x)}{a+b \sec (c+d x)} \, dx &=-\int (-a+b \sec (c+d x)) \, dx\\ &=a x-b \int \sec (c+d x) \, dx\\ &=a x-\frac{b \tanh ^{-1}(\sin (c+d x))}{d}\\ \end{align*}
Mathematica [A] time = 0.0066265, size = 17, normalized size = 1. \[ a x-\frac{b \tanh ^{-1}(\sin (c+d x))}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.043, size = 31, normalized size = 1.8 \begin{align*} ax-{\frac{b\ln \left ( \sec \left ( dx+c \right ) +\tan \left ( dx+c \right ) \right ) }{d}}+{\frac{ac}{d}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 0.497741, size = 95, normalized size = 5.59 \begin{align*} \frac{2 \, a d x - b \log \left (\sin \left (d x + c\right ) + 1\right ) + b \log \left (-\sin \left (d x + c\right ) + 1\right )}{2 \, d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 3.25023, size = 41, normalized size = 2.41 \begin{align*} a x - b \left (\begin{cases} \frac{x \left (\tan{\left (c \right )} \sec{\left (c \right )} + \sec ^{2}{\left (c \right )}\right )}{\tan{\left (c \right )} + \sec{\left (c \right )}} & \text{for}\: d = 0 \\\frac{\log{\left (\tan{\left (c + d x \right )} + \sec{\left (c + d x \right )} \right )}}{d} & \text{otherwise} \end{cases}\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.19349, size = 58, normalized size = 3.41 \begin{align*} \frac{{\left (d x + c\right )} a - b \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 1 \right |}\right ) + b \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1 \right |}\right )}{d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]